package com.ieasy.module.oa.project.web.action;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.ieasy.basic.model.DataGrid;
import com.ieasy.basic.model.Msg;
import com.ieasy.basic.util.cons.Const;
import com.ieasy.module.common.web.action.BaseController;
import com.ieasy.module.oa.project.service.IComapnyMemberCountService;
import com.ieasy.module.oa.project.web.form.ComapnyMemberCountForm;

@Controller
@RequestMapping("/admin/oa/company_member_count")
public class ComapnyMemberCountAction extends BaseController {
	
	@Autowired
	private IComapnyMemberCountService cmService ;
	
	/**
	 * 输入页面
	 * @return
	 */
	@RequestMapping("/company_member_main_UI.do")
	public String company_member_main_UI() {
		return Const.PROJECT + "company_member_main_UI" ;
	}
	
	
	/**
	 * 创建或修改数据
	 * @param form
	 * @return
	 */
	@RequestMapping("/addOrUpdate.do")
	public @ResponseBody Msg addOrUpdate(ComapnyMemberCountForm form) {
		return this.cmService.addOrUpdate(form) ;
	}
	
	
	/**
	 * 部长数据录入计算
	 * @param form
	 * @return
	 */
	@RequestMapping("/company_member_datagrid.do")
	public @ResponseBody DataGrid company_member_datagrid(ComapnyMemberCountForm form) {
		return this.cmService.dagagrid(form) ;
	}
	

}
